Skip to content
This repository was archived by the owner on Apr 29, 2020. It is now read-only.

chore: convert tests to use in memory ipld #4

Merged
merged 4 commits into from
Dec 19, 2018

Conversation

achingbrain
Copy link
Collaborator

Also renames .js tests to .spec.js and removes some unused dependencies from package.json.

@ghost ghost assigned achingbrain Dec 13, 2018
@ghost ghost added the in progress label Dec 13, 2018
@vmx
Copy link
Contributor

vmx commented Dec 13, 2018

@achingbrain As you don't do anything special in your test/browser.js and test/node.js you can just remove them. I actually prefer that as you then clearly signal that you can also run the tests individually.


pull(
values([
{ path: 'a/b/c/d/e', content: pull.values([Buffer.from('banana')]) },
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is an exemplarily comment. There's some calls with pull.* in the tests. I don't have a clue why they work. I made some code changes on top of this PR and then the tests failed for me.

Anyway, I guess it makes sense to replace all occurrences of pull.* with there * counterparts.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interesting. I'm going to merge this PR, will do another with the pull.* to * change, otherwise this runs the risk of becoming a 'general improvements' thread.

What were the changes you made that meant these tests stop working?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried to find out what made things not working, but I couldn't. It is during my IPLD API changes stuff, so it's a lot of dependencies changing and also a lot of linking involved. Hence hard to tell what made it fail.

@achingbrain
Copy link
Collaborator Author

As you don't do anything special in your test/browser.js and test/node.js you can just remove them.

Ah, cool - I thought they were required by Aegir. I guess they're only necessary if your tests aren't called *.spec.js?

@vmx
Copy link
Contributor

vmx commented Dec 19, 2018

I guess they're only necessary if your tests aren't called *.spec.js

Exactly!

@achingbrain achingbrain merged commit 03f58a8 into master Dec 19, 2018
@achingbrain achingbrain deleted the convert-tests-to-use-in-memory-ipld branch December 19, 2018 12:01
@ghost ghost removed the in progress label Dec 19, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants